/**
 * 
 */
package com.tcc.qa.test.util;

import org.openqa.selenium.By;
import org.openqa.selenium.NoSuchElementException;
import org.openqa.selenium.WebDriver;



/**
 * @company CampusCruiser
 * @author Emily_Wang
 * @date 2012-7-10
 */
public class JudgeWebElement {
	public static boolean doesWebElementExist(WebDriver driver, By selector) { 
        try { 
                driver.findElement(selector); 
               return true; 
        } catch (NoSuchElementException e) { 
            return false; 
        } 
    } 
}
